package com.czn.shopdemo.utils;
import com.alipay.api.AlipayClient;
import com.alipay.api.DefaultAlipayClient;

public class AliPayUtils {
    public static AlipayClient alipayClient;
    static {
        alipayClient =
                new DefaultAlipayClient(
                      "https://openapi.alipaydev.com/gateway.do",
                        "2021000122671832",
                        "MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDdxaV7VuoDdAgovOxPh3X+ibUD4bAPseLsgmoAUlgSqrRGbE7Bu9clvf4Tl1v73HSTSxbuatA1x2k2DSryeMXrlYXTg0jIaFotUaSn/7iv9tyqEexMazPMNU+R2DfRI6QdNOw3j73JaehN2AIkxsVKQxgdphGeg3ZMxn3bk2zHaEAbYBzUjn8Fo7wPff1ToLL0kE3uXQzs46MjeRNrnAZ0s6mj/phxDOqVB4Ia66qIsrD3pHduVrsLoavoxEKLaXnLX3976jSUKl6jb29iMW9S69gjG7Spj1DsRPKuSjCRFQQ8++usJlitMCViaxO2t470Izqt1Pe5TFcMWJgaQsz3AgMBAAECggEAdzEd8n9RAJAhPnvjag78/NPYRQDMVnMd6k1hWVDoYwf6Igtd/MPPK0rEvpTP7DqdMPjflz4zL2RAiLtlBLKidS6EoZxixstHBCpoG57WDUTZblJ5tMy9JxjT7ifOQAouzz+9YVNRBmp0XzokVM28BWCwGmdB+vbe4v6fcB75DOZbwpl59riEp+FS2gSPqiPos5yINBwDwlKOh/IU1MOVa+AZ0cfd7Db6Jmjv2vRO+oiPy8kNYQSlh6O0IWF/tAwS3G4khDpQlRU0GWQFBfqF91i8pA2etOachnlWQbHDqU1WREaF8aqSDbiCtonzjdpyGLtihrF8nTYMFalWqNjDoQKBgQDw3Mx/CZaOj9HLMit4Puj7+kV0sWSIlEFtKh/fo1DDMFwNshtqFq/LKY+dKffgHKxtC1wf0mq8K3zKtliATdGtflq3KQKVDaSNMxE9rft9lc8izo1dpVJvHQwz2jMWIolroo09Zox7EwhPWGVH4k1rW6FwSnagceS+GAD0GWlXkQKBgQDrtbRPmGE/45phDs6YBCR5U7GvPxOvhdhuVz8L47wgN6m/Lk7z6vfa95glzSu9dt1HX2xJ189P6zCPnQBSqJu5Mmr4fknfgKqSKrfR4ggGjh6a+Iqgsg51WUrdz8e6IXB3xs/pAMbdHPQMcIo31VSTSA3i4XQMU5LgSrKIGaboBwKBgQClSvFvsPXIafxQVOKuB4Y9/heSKHbUn+Fyd/kdsWcoPFS/9V2I5X7IjoIHGhkIjMTrpGMZV352GeXu+0oq6rydMlww3Azwm0c0uzn2uSIgoiFfQp6TCHRU2ntYTkLGyvbBjfEdlPWNNJd8VC5VMYFtzpkwhXl5TA/tQG3PFm1LcQKBgQDEruR8nmxXwXYqkw507s/4pYvY7cthZVBKEmc7ZpauU4RDUUL0ahbUElJVCLT87diLG+biX0BQMbJdw+ZnEuaOTLHSFJ9T7qtmOFsWuYN05NZI/ie/G5TQ+udr21uPxyNv7ufCR7GpA+XpE2diW5KtKyzbKsGJH5upqOr8glsxtQKBgDC1D7hZeDD4XS8N4g8eLsCXdJlDxwVAYxv+WM77HKYhbzjNaeStrALHzL1snpOC5IUtfmr5vFOp42Qk7MMaWd0oDrGIFPQBEkC30dmCwQTfNdYYbVfQ9G/gTnpuxinn4P0o930cwUPmLhyDqnfKVqFJJMhofkMdGK1ExnhkGsB3",
                        "json",
                        //UTF-8编码格式
                        "UTF-8",
                        "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAw6U1QWN7HT7+UdepfeTCmTpkI3UY4CPK0i+IX1463ZyXo/hvglOI24QCGbNpEeeAluEo4JUeCPQBHRRhkSqGO1mIE5pVrchzW+LX48YgOy+vp4cKWh0SzPPGgQQ1krHxEuvUPEYDsCtCV8nnQRrbbwafR2AVs3WmhETzKqCZCN6IzN+VYFZPsB/97Nl8qqajX8imgTsfY/hUQD0Hb9E51rxsJU3Ens5u/DxKZ5jojeJSYN/GkoB9Wl3QnDhFlrIyNWt1I2N+h/JShraUk6/cH5WsDUhoHV7pkHom+iwfBbFyELjRYxYNHhqsW5Y82GhMJXvF04JccBP8VQ7xGXbjZQIDAQAB",
                        //RSA非对称加密
                        "RSA2");
    }
    public static AlipayClient getAlipayClient(){
        return alipayClient;
    }
}

